add metadata put in workflow#19195
Conversation
|
I think the high-level direction looks good, but we probably can improve the structure a little bit. Here there are three metadata for workflow & step (6 in total): For step metadata
For workflow metadata
Let's focus on step metadata first and then we can get to workflow metadata later. |
fishbone
left a comment
There was a problem hiding this comment.
Thanks for the contribution! The highlevel direction looks good! Let's fix the comments and add some test and go with another round of review.
|
@iycheng thanks for the suggestion.
|
|
user meta looks good to me. I got your point. I think you are right about pre-run metadata and post-run metadata. and call them before and after wrap run. ray/python/ray/workflow/step_executor.py Lines 367 to 369 in 76e2130 |
|
@iycheng Update: For all 6 inputs, here are where they are now:
Btw, I think the code changes are now much cleaner, thanks to the early feedbacks. |
fishbone
left a comment
There was a problem hiding this comment.
Really thanks for the updating! It looks nice! I have some comments there which shouldn't be too hard to fix
- let's try to keep workflow storage clean without logic related to the application
- except for user-facing API, let's rename metadata to user_metadata if it's from the user. Because for user-facing API, there is only one type of metadata so no confusion there. But internally, we have several kinds of metadata.
- once fixed them, please add some test cases you can follow the pattern here (python/ray/workflow/tests/test_basic_workflows_2.py)
|
@iycheng added tests in 93eb53f. |
|
There is lint failure, could you check this doc and format it? |
|
it looks like rllib test failed. It looks like not related to this one. Could you merge to master and push it again? |
|
Everything else looks good! It's almost there and thanks for the work! |
|
lint failure |
@iycheng can you help me on this one? I checked all failed checks and there is only one related - However, |
Usually I run |
fishbone
left a comment
There was a problem hiding this comment.
Thanks for the contribution!
|
Test failure looks unrelated. @lchu-ibm could you give more details in the description part? |
|
@iycheng done with updating description. |
Why are these changes needed?
Add metadata to workflow. Currently there is no option for user to attach any metadata to a step or workflow run, and workflow running metrics (except status) are not captured nor checkpointed.
We are adding various of metadata including:
step.options(metadata={})workflow.run(metadata={})Related issue number
#17090
Checks
scripts/format.shto lint the changes in this PR.